package cn.iocoder.yudao.module.member.api.siteconfig;

import cn.hutool.core.bean.BeanUtil;
import cn.iocoder.yudao.module.member.api.siteconfig.dto.SiteConfigurationDto;
import cn.iocoder.yudao.module.member.controller.admin.siteconfig.vo.SiteConfigurationVo;
import cn.iocoder.yudao.module.member.service.siteconfiguration.SiteConfigurationService;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @author liujq
 * @date 20241220 22:21
 */
@Service
public class SiteConfigurationApiImpl implements SiteConfigurationApi{
    @Resource
    @Lazy
    private SiteConfigurationService siteConfigurationService;
    @Override
    public SiteConfigurationDto getConfig() {
        SiteConfigurationVo config = siteConfigurationService.getConfig();

        return BeanUtil.copyProperties(config, SiteConfigurationDto.class);
    }
}
